<html>
   <head>
      <link rel="stylesheet" type="text/css" href="style.css" />
   </head>
   <body onload="">
<h2 class="comptitle">NED File <i>src/underlay/inetunderlay/InetUnderlay.ned</i></h2>
<table class="typetable">
   <tr>
      <th>Name</th>
      <th>Description</th>
   </tr>
<tr>
   <td>
      <a href="oversim.underlay.inetunderlay.InetUnderlayNetwork.html">InetUnderlayNetwork</a>
      <i> (network)</i>
   </td>
   <td>

<p>The InetUnderlay ned-file </p>
<p><b>See also:</b> <a href="oversim.underlay.inetunderlay.InetUnderlayConfigurator.html">InetUnderlayConfigurator</a></p>
   </td>
</tr>
</table>
<h3 class="subtitle">Source code:</h3>
<pre class="src"><span style="color: #808080; font-style: italic; ">//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
//
</span><span style="color: #000000; ">

</span><span style="color: #800000; font-weight: bold; ">package</span><span style="color: #000000; "> </span><span style="color: #000000; ">oversim</span><span style="color: #000000; ">.</span><span style="color: #000000; ">underlay</span><span style="color: #000000; ">.</span><span style="color: #000000; ">inetunderlay</span><span style="color: #000000; ">;

</span><span style="color: #800000; font-weight: bold; ">import</span><span style="color: #000000; "> </span><span style="color: #000000; ">oversim</span><span style="color: #000000; ">.</span><span style="color: #000000; ">common</span><span style="color: #000000; ">.</span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; ">;
</span><span style="color: #800000; font-weight: bold; ">import</span><span style="color: #000000; "> </span><span style="color: #000000; ">oversim</span><span style="color: #000000; ">.</span><span style="color: #000000; ">common</span><span style="color: #000000; ">.</span><span style="color: #000000; ">GlobalObserver</span><span style="color: #000000; ">;
</span><span style="color: #800000; font-weight: bold; ">import</span><span style="color: #000000; "> </span><span style="color: #000000; ">oversim</span><span style="color: #000000; ">.</span><span style="color: #000000; ">common</span><span style="color: #000000; ">.</span><span style="color: #000000; ">ChurnGenerator</span><span style="color: #000000; ">;


</span><span style="color: #808080; font-style: italic; ">//
// The InetUnderlay ned-file </span><span style="color: #000080; ">@see</span><span style="color: #808080; font-style: italic; "> InetUnderlayConfigurator
//
</span><span style="color: #800000; font-weight: bold; ">network</span><span style="color: #000000; "> </span><span style="color: #000000; ">InetUnderlayNetwork</span><span style="color: #000000; ">
{
    </span><span style="color: #800000; font-weight: bold; ">parameters</span><span style="color: #000000; ">:
        </span><span style="color: #000080; font-weight: bold; ">string</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayType</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// the overlay used in the simulation (for overlayBackboneRouters)
</span><span style="color: #000000; ">        </span><span style="color: #000080; font-weight: bold; ">string</span><span style="color: #000000; "> </span><span style="color: #000000; ">tier1Type</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// the application on top of the overlay used in the simulation (for overlayBackboneRouters)
</span><span style="color: #000000; ">        </span><span style="color: #000080; font-weight: bold; ">string</span><span style="color: #000000; "> </span><span style="color: #000000; ">tier2Type</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// the module type on top of tier 1 (for overlayBackboneRouters)
</span><span style="color: #000000; ">        </span><span style="color: #000080; font-weight: bold; ">string</span><span style="color: #000000; "> </span><span style="color: #000000; ">tier3Type</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// the module type on top of tier 2 (for overlayBackboneRouters)
</span><span style="color: #000000; ">        </span><span style="color: #000080; font-weight: bold; ">int</span><span style="color: #000000; "> </span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// number of backbone routers in the network
</span><span style="color: #000000; ">        </span><span style="color: #000080; font-weight: bold; ">int</span><span style="color: #000000; "> </span><span style="color: #000000; ">accessRouterNum</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// number of access routers in the network
</span><span style="color: #000000; ">        </span><span style="color: #000080; font-weight: bold; ">int</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// number of backbone routers in the network that participate the overlay
</span><span style="color: #000000; ">        </span><span style="color: #000080; font-weight: bold; ">int</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayAccessRouterNum</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// number of access routers in the network that participate the overlay
</span><span style="color: #000000; ">        </span><span style="color: #000080; font-weight: bold; ">int</span><span style="color: #000000; "> </span><span style="color: #000000; ">outRouterNum</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// set to 1 if you want to use a TunOutRouter as connection to a real network
</span><span style="color: #000000; ">        </span><span style="color: #000080; font-weight: bold; ">double</span><span style="color: #000000; "> </span><span style="color: #000000; ">connectivity</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// degree of connectivity of backbone routers (1 = every backbone router is connected to all the others)
</span><span style="color: #000000; ">    </span><span style="color: #800000; font-weight: bold; ">submodules</span><span style="color: #000000; ">:
        </span><span style="color: #000000; ">overlayTerminal</span><span style="color: #000000; ">[</span><span style="color: #008000; ">0</span><span style="color: #000000; ">]: </span><span style="color: #000000; ">InetOverlayHost</span><span style="color: #000000; "> {
            </span><span style="color: #000000; font-weight: bold; ">@dynamic</span><span style="color: #000000; ">;
        }
        </span><span style="color: #000000; ">underlayConfigurator</span><span style="color: #000000; ">: </span><span style="color: #000000; ">InetUnderlayConfigurator</span><span style="color: #000000; "> {
            </span><span style="color: #000000; font-weight: bold; ">@display</span><span style="color: #000000; ">(</span><span style="color: #008000; ">&quot;p=70,160&quot;</span><span style="color: #000000; ">);
        }
        </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">]: </span><span style="color: #000000; ">Router</span><span style="color: #000000; "> {
            </span><span style="color: #800000; font-weight: bold; ">parameters</span><span style="color: #000000; ">:
                </span><span style="color: #000000; font-weight: bold; ">@display</span><span style="color: #000000; ">(</span><span style="color: #008000; ">&quot;i=device/server2&quot;</span><span style="color: #000000; ">);
        }
        </span><span style="color: #000000; ">outRouter</span><span style="color: #000000; ">[</span><span style="color: #800080; font-weight: bold; ">min</span><span style="color: #000000; ">(</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">outRouterNum</span><span style="color: #000000; ">)]: </span><span style="color: #000000; ">TunOutRouter</span><span style="color: #000000; ">;
        </span><span style="color: #000000; ">accessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">accessRouterNum</span><span style="color: #000000; ">]: </span><span style="color: #000000; ">AccessRouter</span><span style="color: #000000; "> {
            </span><span style="color: #800000; font-weight: bold; ">parameters</span><span style="color: #000000; ">:
                </span><span style="color: #000000; font-weight: bold; ">@display</span><span style="color: #000000; ">(</span><span style="color: #008000; ">&quot;i=device/server2,gray,30&quot;</span><span style="color: #000000; ">);
        }
        </span><span style="color: #000000; ">overlayAccessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">overlayAccessRouterNum</span><span style="color: #000000; ">]: </span><span style="color: #000000; ">OverlayAccessRouter</span><span style="color: #000000; "> {
            </span><span style="color: #800000; font-weight: bold; ">parameters</span><span style="color: #000000; ">:
                </span><span style="color: #000000; ">overlayType</span><span style="color: #000000; "> = </span><span style="color: #000000; ">overlayType</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// the overlay used in the simulation
</span><span style="color: #000000; ">                </span><span style="color: #000000; ">tier1Type</span><span style="color: #000000; "> = </span><span style="color: #000000; ">tier1Type</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// the application on top off the overly used in the simulation
</span><span style="color: #000000; ">                </span><span style="color: #000000; ">tier2Type</span><span style="color: #000000; "> = </span><span style="color: #000000; ">tier2Type</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// tier 2 module to use
</span><span style="color: #000000; ">                </span><span style="color: #000000; ">tier3Type</span><span style="color: #000000; "> = </span><span style="color: #000000; ">tier3Type</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// tier 3 module to use
</span><span style="color: #000000; ">                </span><span style="color: #000000; font-weight: bold; ">@display</span><span style="color: #000000; ">(</span><span style="color: #008000; ">&quot;i=device/server2,gray,30;i2=block/circle_s&quot;</span><span style="color: #000000; ">);
        }
        </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">]: </span><span style="color: #000000; ">OverlayRouter</span><span style="color: #000000; "> {
            </span><span style="color: #800000; font-weight: bold; ">parameters</span><span style="color: #000000; ">:
                </span><span style="color: #000000; ">overlayType</span><span style="color: #000000; "> = </span><span style="color: #000000; ">overlayType</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// the overlay used in the simulation
</span><span style="color: #000000; ">                </span><span style="color: #000000; ">tier1Type</span><span style="color: #000000; "> = </span><span style="color: #000000; ">tier1Type</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// the application on top off the overly used in the simulation
</span><span style="color: #000000; ">                </span><span style="color: #000000; ">tier2Type</span><span style="color: #000000; "> = </span><span style="color: #000000; ">tier2Type</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// tier 2 module to use
</span><span style="color: #000000; ">                </span><span style="color: #000000; ">tier3Type</span><span style="color: #000000; "> = </span><span style="color: #000000; ">tier3Type</span><span style="color: #000000; ">;    </span><span style="color: #808080; font-style: italic; ">// tier 3 module to use
</span><span style="color: #000000; ">                </span><span style="color: #000000; font-weight: bold; ">@display</span><span style="color: #000000; ">(</span><span style="color: #008000; ">&quot;i=device/server2;i2=block/circle_s&quot;</span><span style="color: #000000; ">);
        }
        </span><span style="color: #000000; ">churnGenerator</span><span style="color: #000000; ">[</span><span style="color: #008000; ">0</span><span style="color: #000000; ">]: </span><span style="color: #000000; ">ChurnGenerator</span><span style="color: #000000; "> {
            </span><span style="color: #000000; font-weight: bold; ">@display</span><span style="color: #000000; ">(</span><span style="color: #008000; ">&quot;p=70,240,column&quot;</span><span style="color: #000000; ">);
        }
        </span><span style="color: #000000; ">globalObserver</span><span style="color: #000000; ">: </span><span style="color: #000000; ">GlobalObserver</span><span style="color: #000000; "> {
            </span><span style="color: #800000; font-weight: bold; ">parameters</span><span style="color: #000000; ">:
                </span><span style="color: #000000; font-weight: bold; ">@display</span><span style="color: #000000; ">(</span><span style="color: #008000; ">&quot;i=block/control;p=70,50&quot;</span><span style="color: #000000; ">);
        }

    </span><span style="color: #800000; font-weight: bold; ">connections</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">allowunconnected</span><span style="color: #000000; ">:

        </span><span style="color: #808080; font-style: italic; ">//
</span><span style="color: #000000; ">        </span><span style="color: #808080; font-style: italic; ">// BACKBONE ROUTER
</span><span style="color: #000000; ">        </span><span style="color: #808080; font-style: italic; ">//
</span><span style="color: #000000; ">        </span><span style="color: #808080; font-style: italic; ">// connect outRouter to a backboneRouter
</span><span style="color: #000000; ">        </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #008000; ">0</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">outRouter</span><span style="color: #000000; ">[</span><span style="color: #008000; ">0</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">outRouterNum</span><span style="color: #000000; ">&gt;</span><span style="color: #008000; ">0</span><span style="color: #000000; ">;
        </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #008000; ">0</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">outRouter</span><span style="color: #000000; ">[</span><span style="color: #008000; ">0</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">outRouterNum</span><span style="color: #000000; ">&gt;</span><span style="color: #008000; ">0</span><span style="color: #000000; ">;

        </span><span style="color: #808080; font-style: italic; ">// connect backboneRouters with other backboneRouters
</span><span style="color: #000000; ">        </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">j</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; "> {
            </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">j</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">&lt;</span><span style="color: #000000; ">j</span><span style="color: #000000; ">&amp;&amp;</span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">connectivity</span><span style="color: #000000; ">;
            </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">j</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">&lt;</span><span style="color: #000000; ">j</span><span style="color: #000000; ">&amp;&amp;</span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">connectivity</span><span style="color: #000000; ">;
        }

        </span><span style="color: #808080; font-style: italic; ">// connect backboneRouters with overlayBackboneRouters
</span><span style="color: #000000; ">        </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">j</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; "> {
            </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">j</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">&lt;=</span><span style="color: #000000; ">j</span><span style="color: #000000; ">&amp;&amp;</span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">connectivity</span><span style="color: #000000; ">;
            </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">j</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">&lt;=</span><span style="color: #000000; ">j</span><span style="color: #000000; ">&amp;&amp;</span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">connectivity</span><span style="color: #000000; ">;
        }

        </span><span style="color: #808080; font-style: italic; ">// connect overlayBackboneRouters with backboneRouters
</span><span style="color: #000000; ">        </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">j</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; "> {
            </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">j</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">&lt;</span><span style="color: #000000; ">j</span><span style="color: #000000; ">&amp;&amp;</span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">connectivity</span><span style="color: #000000; ">;
            </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">j</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">&lt;</span><span style="color: #000000; ">j</span><span style="color: #000000; ">&amp;&amp;</span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">connectivity</span><span style="color: #000000; ">;
        }

        </span><span style="color: #808080; font-style: italic; ">// connect overlayBackboneRouters with other overlayBackboneRouters
</span><span style="color: #000000; ">        </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">j</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; "> {
            </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">j</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">&lt;</span><span style="color: #000000; ">j</span><span style="color: #000000; ">&amp;&amp;</span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">connectivity</span><span style="color: #000000; ">;
            </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">j</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">&lt;</span><span style="color: #000000; ">j</span><span style="color: #000000; ">&amp;&amp;</span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">connectivity</span><span style="color: #000000; ">;
        }

        </span><span style="color: #808080; font-style: italic; ">//
</span><span style="color: #000000; ">        </span><span style="color: #808080; font-style: italic; ">// ACCESS ROUTER
</span><span style="color: #000000; ">        </span><span style="color: #808080; font-style: italic; ">//
</span><span style="color: #000000; ">        </span><span style="color: #808080; font-style: italic; ">// connect accessRouters with backboneRouters
</span><span style="color: #000000; ">        </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">accessRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; "> {
            </span><span style="color: #000000; ">accessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">intuniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">)].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">)&gt;</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">/(</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">+</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">);
            </span><span style="color: #000000; ">accessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">intuniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&gt;</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">/(</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">+</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">);
        }

        </span><span style="color: #808080; font-style: italic; ">// connect accessRouters with overlayBackboneRouters
</span><span style="color: #000000; ">        </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">accessRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; "> {
            </span><span style="color: #000000; ">accessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">intuniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">)].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">/(</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">+</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">);
            </span><span style="color: #000000; ">accessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">intuniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">/(</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">+</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">);
        }

        </span><span style="color: #808080; font-style: italic; ">// connect overlayAccessRouters with backboneRouters
</span><span style="color: #000000; ">        </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">overlayAccessRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; "> {
            </span><span style="color: #000000; ">overlayAccessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">intuniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">)].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">)&gt;</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">/(</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">+</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">);
            </span><span style="color: #000000; ">overlayAccessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">backboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">intuniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&gt;</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">/(</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">+</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">);
        }

        </span><span style="color: #808080; font-style: italic; ">// connect overlayAccessRouters with overlayBackboneRouters
</span><span style="color: #000000; ">        </span><span style="color: #800000; font-weight: bold; ">for</span><span style="color: #000000; "> </span><span style="color: #000000; ">i</span><span style="color: #000000; ">=</span><span style="color: #008000; ">0</span><span style="color: #000000; ">..</span><span style="color: #000000; ">overlayAccessRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; "> {
            </span><span style="color: #000000; ">overlayAccessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">--&gt;</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">intuniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">)].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">/(</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">+</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">);
            </span><span style="color: #000000; ">overlayAccessRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">i</span><span style="color: #000000; ">].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">i</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">inet_fiberline</span><span style="color: #000000; "> </span><span style="color: #800000; font-weight: bold; ">&lt;--</span><span style="color: #000000; "> </span><span style="color: #000000; ">overlayBackboneRouter</span><span style="color: #000000; ">[</span><span style="color: #000000; ">intuniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">-</span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)].</span><span style="color: #000000; ">pppg</span><span style="color: #000000; ">$</span><span style="color: #000000; ">o</span><span style="color: #000000; ">++ </span><span style="color: #800000; font-weight: bold; ">if</span><span style="color: #000000; "> </span><span style="color: #000000; ">uniform2</span><span style="color: #000000; ">(</span><span style="color: #008000; ">0</span><span style="color: #000000; ">, </span><span style="color: #008000; ">1</span><span style="color: #000000; ">, </span><span style="color: #000000; ">i</span><span style="color: #000000; ">, </span><span style="color: #008000; ">0</span><span style="color: #000000; ">)&lt;=</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">/(</span><span style="color: #000000; ">overlayBackboneRouterNum</span><span style="color: #000000; ">+</span><span style="color: #000000; ">backboneRouterNum</span><span style="color: #000000; ">);
        }

}
</span></pre>
   <hr><p class="footer"><a href="http://creativecommons.org/licenses/by-sa/3.0" target="_top"><img src="by-sa.png"></a> This documentation is released under the <a href="http://creativecommons.org/licenses/by-sa/3.0" target="_top">Creative Commons license</a></p>
   </body>
</html>
